﻿using personalplaner.common;
using personalplaner.common.mvvm.factory;
using personalplaner.servicemodel.dataaccess;

namespace personalplaner.gui.stamm.viewmodels.factories
{
	public class FeiertageStammModelFactory : IFactory
	{
		#region IFactory Members
		
		public object CreateViewModel(System.Windows.DependencyObject sender)
        {
			var vm = new FeiertageStammViewModel(sender);

			vm.ServiceLocator.RegisterService<ICommonDataAccess>(new CommonDataAccess(SettingsProvider.Settings));
            
            return vm;
		}

		#endregion
	}
}
